//
//  ChooseGoodCell.m
//  自定义商品选择窗口
//
//  Created by 孙鹏飞 on 2017/6/26.
//  Copyright © 2017年 homai. All rights reserved.
//

#import "ChooseGoodCell.h"
#import "ChooseGoodModel.h"

@interface ChooseGoodCell ()

@property (weak, nonatomic) IBOutlet UILabel *titleName;

@property (weak, nonatomic) IBOutlet UIImageView *selectedImage;

@end

@implementation ChooseGoodCell

- (void)awakeFromNib {
    [super awakeFromNib];
    // Initialization code
    self.selectionStyle = UITableViewCellSelectionStyleNone;
}

- (void)setModel:(ChooseGoodModel *)model
{
    _model = model;
    self.titleName.text = _model.name;
    
    if (_model.isChecked) {
        self.selectedImage.hidden = NO;
    } else {
        self.selectedImage.hidden = YES;
    }
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}

@end
